chore: add prettier for markdown and astro formatting#2153
Conversation
…provider, context, hooks, and query utilities are now exported from `@namehash/namehash-ui`.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
|
Warning Rate limit exceeded
You’ve run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (10)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
This PR introduces Prettier into the monorepo to standardize formatting for Markdown at the root and Astro files within the docs workspaces, complementing Biome (which handles the rest of the codebase).
Changes:
- Add Prettier (and Astro plugin) to the pnpm catalog/lockfile and introduce root-level
.prettierrc.json/.prettierignore. - Update root
lint/lint:cito run Prettier on Markdown and run workspace-level Astro format checks where available. - Add docs workspace Prettier configs and
format/format:checkscripts for.astrofiles.
Reviewed changes
Copilot reviewed 10 out of 11 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| pnpm-workspace.yaml | Adds prettier and prettier-plugin-astro to the shared catalog. |
| pnpm-lock.yaml | Locks new Prettier dependencies and updates related Astro dependency snapshots. |
| package.json | Updates lint scripts to include Prettier checks/writes and adds Prettier devDependency. |
| docs/ensrainbow.io/package.json | Adds format scripts and Prettier devDependencies for .astro formatting. |
| docs/ensrainbow.io/.prettierrc.json | Adds Astro-specific Prettier configuration via prettier-plugin-astro. |
| docs/ensrainbow.io/.prettierignore | Excludes build artifacts from Prettier in the docs workspace. |
| docs/ensnode.io/package.json | Adds format scripts and Prettier devDependencies for .astro formatting. |
| docs/ensnode.io/.prettierrc.json | Adds Astro-specific Prettier configuration via prettier-plugin-astro. |
| docs/ensnode.io/.prettierignore | Excludes build artifacts from Prettier in the docs workspace. |
| .prettierrc.json | Introduces root Prettier defaults for Markdown/prose formatting. |
| .prettierignore | Excludes generated/owned files (e.g. lockfile, changelogs) from Prettier. |
| .changeset/upset-kids-drop.md | Adds a changeset entry (content currently appears unrelated to this PR). |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| "lint": "pnpm exec prettier --write \"**/*.md\" && pnpm -r --parallel --if-present run format && biome check --write .", | ||
| "lint:ci": "pnpm exec prettier --check \"**/*.md\" && pnpm -r --parallel --if-present run format:check && biome ci", |
There was a problem hiding this comment.
Config here states {md,mdx}?
| "lint": "biome check --write .", | ||
| "lint:ci": "biome ci", | ||
| "lint": "pnpm exec prettier --write \"**/*.md\" && pnpm -r --parallel --if-present run format && biome check --write .", | ||
| "lint:ci": "pnpm exec prettier --check \"**/*.md\" && pnpm -r --parallel --if-present run format:check && biome ci", |
There was a problem hiding this comment.
This is what Prettier is for...
| @@ -0,0 +1,13 @@ | |||
| { | |||
| "scripts": { | ||
| "lint": "biome check --write .", | ||
| "lint:ci": "biome ci", | ||
| "lint": "pnpm exec prettier --write \"**/*.md\" && pnpm -r --parallel --if-present run format && biome check --write .", |
There was a problem hiding this comment.
i think it'd be simplest and easiest to reason about if we did the following
"lint": "pnpm run -w \"/^lint:[.!:]*$/\"",
// ^- make this run lint:prettier and lint:biome in parallel
"lint:ci": "pnpm run -w \"/^lint:.*:ci$/\"",
"lint:prettier": "pnpm exec prettier --write \"**/*.md\" && pnpm -r lint:prettier",
"lint:prettier:ci": "pnpm exec prettier --check \"**/*.md\" && pnpm -r lint:prettier:ci",
"lint:biome": "biome check --write .",
"lint:biome:ci": "biome ci"
and then define the lint:prettier and `lint:biome
or rename format:check to format:ci to follow biome pattern and keep the current structure.
don't think --if-present is necessary when using -r, it's implied
There was a problem hiding this comment.
- The end goal is to have
lintandlint:cicommands that, when called, perform bothbiomeandprettieractions together. - When we call
pnpm lintat the repo root or project/package root, all files affected should be fully formatted
-- that was specifically requested by @lightwalker-eth when I was making these changes in ENSAwards.
- As long as that's met, I think it's okay to make it more modular as @shrugs suggests.
- I'd also be in favor of removing the
format*commands and handling it all withlint*, assuming that's possible
Lite PR
Tip: Review docs on the ENSNode PR process
Summary
**/*.md(biome handles everything else)Why
.astroTesting
Notes for Reviewer (Optional)
We need to consider when we merge this... as running the lint beyond merging this will cause significant changes to

md/mdx/astrofiles.CHANGELOG.mdignored (owned by changesets)astroSkipFrontmatterlets biome keep formatting.astroscript blocksdocs/ensnode.io and docs/ensrainbow.ioown.astroviaprettier-plugin-astroPre-Review Checklist (Blocking)